<?php

define('ROOT_PATH', realpath(dirname(__FILE__) . '/..'));
define('APPLICATION_PATH', ROOT_PATH . '/application');

set_include_path(ROOT_PATH . DIRECTORY_SEPARATOR . 'library');

require_once 'Zend/Loader.php';

Zend_Loader::registerAutoload();

//$front = Zend_Controller_Front::getInstance();
//$front->registerPlugin(new Zend_Controller_Plugin_ErrorHandler());

$db = Zend_Db::factory('Pdo_Mysql', array(
    'host'             => 'localhost',
    'username'         => 'nweb_zfc',
    'password'         => 'quoh7ooz3geeCh1waiSe',
    'dbname'           => 'nweb_zfc'
));

$db->query('SET NAMES utf8');

Zend_Db_Table_Abstract::setDefaultAdapter($db);
Zend_Controller_Front::run(APPLICATION_PATH . '/controllers');